/*
 * File Name：Sentence.java
 * Copyright：Copyright 2008-2013 CiWong.Inc. All Rights Reserved.
 * Description： Sentence.java
 * Modify By：PLA-ZJLIU
 * Modify Date：2013-12-13
 * Modify Type：Add
 */
package com.ciwong.epaper.modules.evaluate.bean;

import com.ciwong.epaper.modules.epaper.bean.CorrectLinesRelut;
import com.ciwong.libs.oralevaluate.bean.EvaluateResult;

import java.io.Serializable;
import java.util.List;

/**
 * 句子
 *
 * @author PLA-ZJLIU
 * @version ciwong v.1.0 2013-12-13
 * @since ciwong v.1.0
 */
public class Sentence implements Serializable {
    /**
     *
     */
    private static final long serialVersionUID = 1l;

    private String textId;//资源版本ID

    private String text;//评分文本

    private String answer;// 答题解析

    private boolean isSelect;// 是否选中

    private boolean hasGrade;// 是否已经评分
    private int score;

    /**
     * 开始播放位置（毫秒）
     */
    private int start;

    /**
     * 持续播放时间（毫秒）
     */
    private int duration;


    private List<WordDetail> wordDetails;

    private String sentenceMp3;
    /**
     * 翻译
     */
    private String translate;

    private EvaluateResult er;

    private CorrectLinesRelut aser;
    /**
     * 句子图片URL地址
     */
    private String imgUrl;

    private String soundUrl;   //录音文件地址

    private String urlLiYun;  //阿里云上传的地址

    private float fluency;
    private float integrity;
    private float pronunciation;
    private int count;

    public int getCount() {
        return count;
    }

    public void setCount(int count) {
        this.count = count;
    }

    public float getFluency() {
        return fluency;
    }

    public void setFluency(float fluency) {
        this.fluency = fluency;
    }

    public float getIntegrity() {
        return integrity;
    }

    public void setIntegrity(float integrity) {
        this.integrity = integrity;
    }

    public float getPronunciation() {
        return pronunciation;
    }

    public void setPronunciation(float pronunciation) {
        this.pronunciation = pronunciation;
    }

    //音标
    private String lines;

    public String getAnswer() {
        return answer;
    }

    public void setAnswer(String answer) {
        this.answer = answer;
    }

    public String getImgUrl() {
        return imgUrl;
    }

    public void setImgUrl(String imgUrl) {
        this.imgUrl = imgUrl;
    }

    public String getTranslate() {
        return translate;
    }

    public void setTranslate(String translate) {
        this.translate = translate;
    }

    public String getTextId() {
        return textId;
    }

    public void setTextId(String textId) {
        this.textId = textId;
    }

    public String getText() {
        return text;
    }

    public void setText(String text) {
        this.text = text;
    }

    public boolean hasGrade() {
        return hasGrade;
    }

    public void setHasGrade(boolean hasGrade) {
        this.hasGrade = hasGrade;
    }

    public int getScore() {
        return score;
    }

    public void setScore(int score) {
        this.score = score;
    }

    public List<WordDetail> getWordDetails() {
        return wordDetails;
    }

    public void setWordDetails(List<WordDetail> wordDetails) {
        this.wordDetails = wordDetails;
    }

    public String getSentenceMp3() {
        return sentenceMp3;
    }

    public void setSentenceMp3(String sentenceMp3) {
        this.sentenceMp3 = sentenceMp3;
    }

    public int getStart() {
        return start;
    }

    public void setStart(int start) {
        this.start = start;
    }

    public int getDuration() {
        return duration;
    }

    public void setDuration(int duration) {
        this.duration = duration;
    }

    public void setTextColor(int color) {
        int len = wordDetails == null ? 0 : wordDetails.size();
        for (int i = 0; i < len; i++) {
            final WordDetail w = wordDetails.get(i);
            w.setColor(color);
        }
    }

    public EvaluateResult getEr() {
        return er;
    }

    public void setEr(EvaluateResult er) {
        this.er = er;
    }

    public String getSoundUrl() {
        return soundUrl;
    }

    public void setSoundUrl(String soundUrl) {
        this.soundUrl = soundUrl;
    }

    public String getUrlLiYun() {
        return urlLiYun;
    }

    public void setUrlLiYun(String urlLiYun) {
        this.urlLiYun = urlLiYun;
    }

    public String getLines() {
        return lines;
    }

    public void setLines(String lines) {
        this.lines = lines;
    }

    public boolean isSelect() {
        return isSelect;
    }

    public void setSelect(boolean select) {
        isSelect = select;
    }

    public CorrectLinesRelut getAser() {
        return aser;
    }

    public void setAser(CorrectLinesRelut aser) {
        this.aser = aser;
    }

    @Override
    public String toString() {
        return "Sentence{" +
                "textId='" + textId + '\'' +
                ", text='" + text + '\'' +
                ", isSelect=" + isSelect +
                ", hasGrade=" + hasGrade +
                ", score=" + score +
                ", start=" + start +
                ", duration=" + duration +
                ", wordDetails=" + wordDetails +
                ", sentenceMp3='" + sentenceMp3 + '\'' +
                ", translate='" + translate + '\'' +
                ", er=" + er +
                ", imgUrl='" + imgUrl + '\'' +
                ", soundUrl='" + soundUrl + '\'' +
                ", urlLiYun='" + urlLiYun + '\'' +
                ", lines='" + lines + '\'' +
                '}';
    }
}
